<!DOCTYPE html>
<html>
	
	<head>
		<meta charset="UTF-8">
		<title>test box</title>
		<script src="http://code.jquery.com/jquery-2.1.4.min.js"></script>
		<script src="./js/visor.core.js" type="text/javascript" charset="utf-8"></script>
		<script src="./js/visor.widgets.js" type="text/javascript" charset="utf-8"></script>
	</head>

	<body>
		<h4 style="margin: 10px;">运行结果</h4>
		<p style="margin: 10px;">tips:<br> 1、双击控件可修改text值;<br>2、点击box会出现红色的功能点，你可以任意移动它的位置哦！</p>
		<div id="panel" style="position: relative;"></div>
	</body>
	
	<script type="text/javascript">
		var panel = $.presenter({
			name: 'panel',
			width: 450,
			height: 400,
			dom: $("#panel"),
			background: {
				filltype: "color",
				color: "#ddebf9"
			}
		});
		var box1 = $.widgets("box", {
			x: 100,
			y: 30,
			text: "box",
			editable: true,
			font: {
				style: "italic",
				weight: "bold",
				size: "20pt",
				color: "#222"
			}
		}).appendPresenter(panel);

        var box2 = $.widgets("box", {
            x: 100,
            y: 200,
            text: "文本框box文本框box文本框box文本框box文本框box文本框box文本框box文本框box",
            editable: true,
            font: {
                style: "italic",
                weight: "bold",
                size: "16pt",
                color: "#222"
            }
        }).appendPresenter(panel);
		panel.paint();
	</script>

</html>